package club.justwill.single.model;

/**
 * Created by luoyu on 1/3/16.
 */
public class ContentType {
    public static int TEXT = 10;
    public static int IMAGE= 20;
    public static int VEDIO = 30;
    public static int AUDIO = 40;

    public static String getCommentType(int type){
        switch (type){
            case 10 : return "TEXT";
            case 20 : return "IMAGE";
            case 30 : return "VEDIO";
            case 40 : return "AUDIO";
            default: return null;
        }
    }

    public static int getCommentTypeCode(String type){
        if(type.equals("TEXT")) { return 10;}
        if(type.equals("IMAGE")) { return 20;}
        if(type.equals("VEDIO")) { return 30;}
        if(type.equals("AUDIO")) { return 40;}
        return 0;
    }
}
